package com.goldplusgold.live;

import com.goldplusgold.live.bean.CIntroBean;
import com.goldplusgold.live.bean.LDetailBean;
import com.goldplusgold.live.bean.QuestionBean;
import com.goldplusgold.live.bean.SwitchBean;
import com.goldplusgold.live.bean.VDetailBean;
import com.goldplusgold.live.result.ResultAnswers;
import com.goldplusgold.live.result.ResultLikes;
import com.goldplusgold.live.result.ResultLivePlayAddress;
import com.goldplusgold.live.result.ResultLives;
import com.goldplusgold.live.result.ResultLiveQuestions;
import com.goldplusgold.live.result.ResultMessages;
import com.goldplusgold.live.result.ResultRecords;
import com.goldplusgold.live.result.ResultUserQuestions;
import com.goldplusgold.live.result.ResultVideoAnswers;
import com.goldplusgold.live.result.ResultVideoQuestions;
import com.goldplusgold.live.result.ResultVideos;
import com.goldplusgold.live.result.ResultColumns;

import retrofit2.Call;
import retrofit2.http.GET;
import retrofit2.http.Header;
import retrofit2.http.POST;
import retrofit2.http.Query;

/**
 * Created by Administrator on 2017/7/11.
 */

public interface LVideoService {

    @GET("/live/rooms")
    Call<ResultLives> getLives(@Query("offset") int offset, @Query("count") int count);

    @GET("/video/videos")
    Call<ResultVideos> getVideos(@Query("offset") int offset, @Query("count") int count);

    @GET("/column/list")
    Call<ResultColumns> getColumns();

    @GET("/video/detail")
    Call<VDetailBean> getVDetail(@Query("videoID") String videoID);

    @GET("/live/detail")
    Call<LDetailBean> getLDetail(@Query("liveID") String liveID, @Header("Authorization") String token);

    @GET("/live/records")
    Call<ResultRecords>  getRecords(@Query("columnID") String columID, @Query("offset") int offset, @Query("count") int count);

    @GET("/column/intro")
    Call<CIntroBean>  getIntro(@Query("count") int count,@Query("columnID") String columID , @Header("Authorization") String token);

    @GET("/live/messages")
    Call<ResultMessages> getHistoryMessages(@Query("roomID") String roomID,@Query("time") String time,@Query("count")int count);

    @GET("/user/all_ask_answers")
    Call<ResultAnswers> getLiveAnswers(@Query("liveID") String liveID, @Query("offset") int offset, @Query("count")int count);

    @GET("/user/my_questions")
    Call<ResultLiveQuestions> getLiveQuestions(@Query("liveID") String liveID, @Query("offset") int offset, @Query("count")int count, @Header("Authorization") String token);

    @POST("/user/add_question")
    Call<QuestionBean> putLiveQuestion(@Query("liveID") String liveID , @Query("content") String content, @Header("Authorization") String token);

    @POST("/user/add_video_question")
    Call<QuestionBean> putVideoQuestion(@Query("videoID") String liveID , @Query("content") String content, @Header("Authorization") String token);

    @POST("/column/add_likes")
    Call<QuestionBean> follow(@Query("columnID") String lcolumnID, @Header("Authorization") String token);

    @POST("/column/cancel_likes")
    Call<QuestionBean> unFollow(@Query("columnID") String lcolumnID, @Header("Authorization") String token);

    @GET("/user/all_video_ask_answers")
    Call<ResultVideoAnswers> getVideoAnswers(@Query("videoID") String videoID,@Query("offset") int offset,@Query("count")int count);

    @GET("/user/my_video_questions")
    Call<ResultVideoQuestions> getVideoQuestions(@Query("videoID") String videoID,@Query("offset") int offset,@Query("count")int count, @Header("Authorization") String token);

    @GET("/column/likes")
    Call<ResultLikes> getLikes(@Header("Authorization") String token);

    @GET("/user/my_all_questions")
    Call<ResultUserQuestions> getUserQuestions(@Query("offset") int offset, @Query("count")int count, @Header("Authorization") String token);

    @GET("/td_switch")
    Call<SwitchBean> getSwitch();

    @GET("/live/play_address")
    Call<ResultLivePlayAddress> getLivePlayAddress(@Query("liveID") String liveID);
}
